feat: improvements to onboarding flow#1295
Merged
HardeepAsrani merged 3 commits intodevelopmentfrom Mar 30, 2026
Merged
Conversation
Contributor
Soare-Robert-Daniel
approved these changes
Mar 27, 2026
7 tasks
Copilot AI
added a commit
that referenced
this pull request
Mar 27, 2026
…in install, XSS Agent-Logs-Url: https://github.com/Codeinwp/visualizer/sessions/0ea8792d-4154-4e13-989d-301380d262b1 Co-authored-by: selul <3330746+selul@users.noreply.github.com>
Contributor
There was a problem hiding this comment.
Pull request overview
This PR streamlines the Visualizer setup wizard/onboarding flow by reducing the number of steps and consolidating “extra features” + newsletter into a single final step, while updating UI, JS behavior, and E2E coverage accordingly.
Changes:
- Reduced wizard from 5 steps to 3 and redesigned the final step to include optional plugin installs + newsletter opt-in.
- Updated wizard frontend logic to run chart import inline, install selected plugins sequentially, and then finish/redirect.
- Refreshed wizard styling (grid-based chart picker, new option cards) and updated E2E onboarding test to match the new flow.
Reviewed changes
Copilot reviewed 6 out of 9 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| tests/e2e/specs/onboarding.spec.ts | Updates E2E onboarding assertions and interactions for the new 3-step wizard flow. |
| templates/setup-wizard.php | Restructures wizard steps, adds final consolidated “You’re all set!” options UI, adds new plugin-active checks. |
| js/setup-wizard.js | Refactors step transitions (inline import), adds sequential plugin install flow, updates finish/subscribe behavior. |
| css/style-wizard.css | Updates layout/styling for new step structure and chart list grid; adds final-step option card styles. |
| classes/Visualizer/Module/Wizard.php | Improves POST sanitization; returns chart_id on import; generalizes plugin install/activation for multiple slugs. |
| classes/Visualizer/Module/Setup.php | Avoids activation redirect during AJAX/cron; keeps activation redirect behavior for normal admin requests. |
| images/spc-logo.svg | Adds Super Page Cache logo asset for final-step option card UI. |
| images/otter-logo.png | Adds Otter Blocks logo asset for final-step option card UI. |
Comments suppressed due to low confidence (2)
js/setup-wizard.js:38
res.messageis inserted into the DOM via.html(...)(and plugin-install errors are also injected with.html('<p>' + message + '</p>')). To avoid XSS risk from unexpected markup in server-provided messages, prefer.text(...)(or escape before injecting) and build the DOM nodes without string concatenation.
$.post(visualizerSetupWizardData.ajax.url, postData, function (res) {
// Toggle the redirect popup.
$('.redirect-popup').find('h3.popup-title').html(res.message);
$('.redirect-popup').show();
js/setup-wizard.js:393
- This script no longer initializes Slick (the previous
$('.vz-chart-list > ul').slick(...)block was removed), but the wizard still enqueuesslick.min.cssand registersjquery-slickas a dependency for SmartWizard. To avoid loading unused JS/CSS on the wizard screen, consider removing the Slick enqueues/dependency if it’s no longer needed anywhere in the setup wizard.
$(window).bind('pageshow', function() {
if ( jQuery('.vz-chart-option input').is(':checked') ) {
$('#step-1').find('button.disabled').removeClass('disabled');
}
});
});
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Contributor
|
@HardeepAsrani we can merge this one too. Thanks! |
Contributor
|
🎉 This PR is included in version 4.0.0 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR improves the onboarding flow by removing redundant steps and combining them. All e2e related to the PR have passed. The remaining are unrelated to the PR and will be fixed separately.
Will affect visual aspect of the product
YES
Screenshots
Test instructions
Check before Pull Request is ready:
Closes https://github.com/Codeinwp/visualizer-pro/issues/554.